package com.dataseek.iot.device.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dataseek.iot.device.entity.AlarmLog;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.Map;

/**
 * @discription:
 * @author: haijun.li
 * @date: 2022/1/11
 */

@Mapper
public interface AlarmLogMapper extends BaseMapper<AlarmLog> {

    @Select("select a.line_code ," +
            "b.factory_code ," +
            "a.jar_code ," +
            "a.device_code from tenant.liquid_jar a \n" +
            "join tenant.sys_work_line b on a.line_code =b.line_code \n" +
            "where a.device_code =#{deviceCode}")
    public Map queryByDeviceCodeMap(String deviceCode);
}
